//
//  L_pickerView.m
//  school
//
//  Created by edz on 2019/8/9.
//  Copyright © 2019年 edz. All rights reserved.
//

#import "L_pickerView.h"

@interface L_pickerView()<UIPickerViewDataSource,UIPickerViewDataSource>
@property(nonatomic,strong)UIPickerView *pickerView;
@property(nonatomic,strong)NSMutableArray *dataArr;
@property(nonatomic,strong)NSString *Stri;

@end

@implementation L_pickerView

/*
// Only override drawRect: if you perform custom drawing.
// An empty implementation adversely affects performance during animation.
- (void)drawRect:(CGRect)rect {
    // Drawing code
}
*/
static L_pickerView *_loadView = nil;
+(L_pickerView *)shared{
    // static dispatch_once_t predicate  的作用是只执行一次
    
    static dispatch_once_t predicate;
    dispatch_once(&predicate, ^{
        _loadView = [[L_pickerView alloc]init];
        _loadView.frame = CGRectMake(0, 0, ScreenWidth, [UIScreen mainScreen].bounds.size.height);
        _loadView.backgroundColor = [UIColor colorWithRed:0 green:0 blue:0 alpha:0.3];
        _loadView.userInteractionEnabled = YES;
        UITapGestureRecognizer *ges =[[UITapGestureRecognizer alloc]initWithTarget:self action:@selector(clickGes)];
        [_loadView addGestureRecognizer:ges];
        
        //在选择器的页面上面写一个view
        UIView *whiteView = [[UIView alloc]init];
        whiteView.backgroundColor = [UIColor whiteColor];
        [_loadView addSubview:whiteView];
        [whiteView mas_makeConstraints:^(MASConstraintMaker *make) {
            make.left.right.mas_offset(0);
            make.bottom.mas_offset(TabbarSafetyZone);
            make.width.mas_equalTo(BiLiWidth(250));
            
        }];
      
        myLable *lable = [[myLable alloc]init];
        [whiteView addSubview:lable];
        [lable setLabletextColor:[UIColor colorWithRed:132/255.0 green:132/255.0 blue:132/255.0 alpha:1.0] Text:@"选择小朋友" TextFont:12];
        [lable mas_makeConstraints:^(MASConstraintMaker *make) {
            
            make.top.mas_offset(0);
            make.height.mas_offset(40);
            make.centerX.equalTo(whiteView.mas_centerX);
        }];
        
        
        
        
        
        
        
        
    });
   
    
    return _loadView;
    
    
}

- (void)clickGes{
    [L_pickerView  L_dimiss];

}


+ (void)L_dimiss{
    
    
}

@end
